<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script src="js/vue.min.js"></script>
</head>
<body>
<div id="app">
    <p>{{list[0]}}</p>
<!--    循环数组-->
    <p v-for="(item,i) in list">{{item}}------{{i}}</p>
<!--    对象数组-->
    <p v-for="(user,i) in list1">{{user}}---{{user.id}}----{{user.name}}----{{i}}</p>
<!--    循环对象-->
    <p v-for="(val,key,i) in user">值是 {{val}}---键是 {{key}}---索引 {{i}}</p>
<!--    迭代数字-->
    <p v-for="count in 10">这是第 {{count}} 次循环</p>
</div>
<script>
    var vm=new Vue({
        el:'#app',
        data:{
            list:[1,2,3,4,5,6],
            list1:[
                {id:1,name:'zs1'},
                {id:2,name:'zs2'},
                {id:3,name:'zs3'},
                {id:4,name:'zs4'},
            ],
            user:{
                id:11,
                name:'tom',
                gender:'男'
            }
        }
    })
</script>
</body>
</html>